package com.jgp.glmeeting.service.impl;

import com.jgp.glmeeting.model.Template;
import com.jgp.glmeeting.repository.TemplateRepository;
import com.jgp.glmeeting.service.TemplateService;
import com.jgp.sys.common.query.OrderList;
import com.jgp.sys.common.query.QueryFilterList;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class TemplateServiceImpl implements TemplateService {
    @Autowired
    private TemplateRepository templateRepository;
    @Override
    public List<Template> queryAllTem( ) {
//        OrderList orders = new OrderList();
        QueryFilterList queryFilterList=new QueryFilterList();
//        orders.addOrder("createDatetime","desc");
        return templateRepository.read(queryFilterList);
    }

    @Override
    public Template queryById(String id) {
        return templateRepository.read(id);
    }
}
